#include "RCS_shock.h"

#include "esp_log.h"
#include "driver/gpio.h"

static const char *TAG = "SHOCK";

void shock_init(void)
{
    ESP_LOGI(TAG, "shock_init");
    gpio_reset_pin(SHOCK_OUTPUT_PIN);
    /* Set the GPIO as a push/pull output */
    gpio_set_direction(SHOCK_OUTPUT_PIN, GPIO_MODE_OUTPUT);
}
void set_shock(uint8_t state)
{
    /* Set the GPIO level according to the state (LOW or HIGH)*/
    gpio_set_level(SHOCK_OUTPUT_PIN, state);
}
